﻿using SanJ.FreeCare.TypeFramework;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Volo.Abp.Domain.Entities.Auditing;

namespace SanJ.FreeCare.Slots
{
    public class Slot : AuditedAggregateRoot<Guid>
    {
        /// <summary>
        /// Identifier(s) by which this encounter is known
        /// </summary>
        public List<Identifier> Identifier { get; private set; }

        /// <summary>
        /// A broad categorization of the service that is to be performed during this appointment
        /// 预约期间将提供的服务的大致分类
        /// </summary>
        public string[] ServiceCategoryCode {  get; private set; }

        /// <summary>
        /// The type of appointments that can be booked into this slot (ideally this would be an identifiable service - which is at a location, rather than the location itself). If provided then this overrides the value provided on the Schedule resource
        /// 
        /// </summary>
        public Guid[] HealthcareServiceId {  get; private set; }

        /// <summary>
        /// 提供预约服务所需的医生专业Code
        /// </summary>
        public string[] SpecialtyCode { get; private set; }

        /// <summary>
        /// 时段内可预约的预约类型或病人Code（非服务类型）
        /// </summary>
        public string[] AppointmentTypeCode {  get; private set; }

        /// <summary>
        /// 该时隙定义状态信息间隔的时间表资源Id
        /// </summary>
        public Guid ScheduleId {  get; private set; }

        /// <summary>
        /// 状态
        /// 	busy | free | busy-unavailable | busy-tentative | entered-in-error
        /// </summary>
        public string SlotStatusCode { get; private set; }

        /// <summary>
        /// 时段开始的日期/时间
        /// </summary>
        public DateTime? SlotStartTime { get; private set; }

        /// <summary>
        /// 时段结束的日期/时间
        /// </summary>
        public DateTime? SlotEndTime { get; private set; }

        /// <summary>
        /// 该时段已超额预约，不太可能接受该时段的预约
        /// </summary>
        public bool Overbooked { get; private set; }

        /// <summary>
        /// 槽的注释，用于描述任何扩展信息。例如对插槽的自定义限制
        /// </summary>
        public string Comment {  get; private set; }
    }
}
